#include "app_buffer.h"
#include "log/log.h"

int main(int argc, char const *argv[])
{
    Buffer *Test_buf = App_Buffer_Init(20);
    char r_data[100] = {0};
    App_Buffer_Write(Test_buf, "abcde", 5);
    int lenth = App_Buffer_Read(Test_buf, r_data, 100);
    log_debug("read data:%.*s", lenth, r_data);
    App_Buffer_Write(Test_buf, "I love Atguigu", 15);
    lenth = App_Buffer_Read(Test_buf, r_data, 100);
    log_debug("read data:%.*s", lenth, r_data);

    App_Buffer_close(Test_buf);
    return 0;
}
